import request from '@/utils/request'

/**
 * 条件分页查询
 * @param {*} query 
 * @returns 
 */
export const getAlbumListService = (query) => {
    return request.get('/admin/album/page', {
        params: query
    })
}

/**
 * 批量删除
 * @param {*} ids 
 * @returns 
 */
export const deleteBatchService = (ids) => {
    return request.delete('/admin/album', {
        data: ids
    })
}

/**
 * 修改照片状态
 * @param {*} query 
 * @returns 
 */
export const updateStatusService = (id,status) => {
    return request.put('/admin/album/update', {
        id,
        status
    })
}

/**
 * 新增相册
 * @param {*} obj 
 * @returns 
 */
export const addAlbumService = (obj) => {
    return request.post('/admin/album', obj)
}